import sys, os, glob
defs     = ['_GLIBCXX_HAS_GTHREADS', '_REENTRANT', 'DEBUG', 'DEBUGMEM']
includes = ['.', '../shared', '../common', '../fsops', '../hadoopops', '../hadoopops/gen-cpp', '../httplib', '../../includes', '../../includes/thrift']
cflags = '-fpermissive -std=c++0x -ggdb -pthread -Wall -Werror'
name = 'libserverlib.a'
    
files = glob.glob("*.cc") 
env = Environment(CCFLAGS=cflags, CPPDEFINES=defs, CPPPATH=includes)

install_dir = '../../target/libs'
bin = env.StaticLibrary(name, files)
env.Install(install_dir, bin)
env.Alias('install', install_dir)

